/*
 * Lab3.h
 *
 *  Created on: 30.10.2013
 *      Author: ulgish
 */

#ifndef LAB3_H_
#define LAB3_H_

#include <lab3/Room.h>
#include <lab3/RoomSafely.h>
#include <lab3/RoomPrinter.h>
#include <lab3/Thinker.h>
#include <SyncWriter.h>


class Lab3 {
	int maxCountOfThinker;
	int countOfThinkers;
	DT::Room* room;
	DT::RoomSafely* roomSafely;
	DT::RoomPrinter printer;
	DT::Thinker** thinkers;
public:
	Lab3(int countOfThinkers, int maxCountOfThinkers = 5, int minDuration = 3);
	void goDanger(int timeOfModeling);
	void goSafely(int timeOfModeling);
	virtual ~Lab3();
};

#endif /* LAB3_H_ */
